package com.example.train.service.impl;

import com.example.train.service.SysAdminRoleRelationService;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import com.example.train.mapper.SysAdminRoleRelationMapper;
import com.example.train.model.SysAdminRoleRelation;

import java.util.List;

@Service
public class SysAdminRoleRelationServiceImpl implements SysAdminRoleRelationService {

    @Resource
    private SysAdminRoleRelationMapper mapper;

    @Override
    public int deleteByRoleId(long id) {
        return mapper.deleteByRoleId(id);
    }

    @Override
    public int deleteByAdminId(long id) {
        return mapper.deleteByAdminId(id);
    }

    @Override
    public int deleteById(long id) {
        return mapper.deleteById(id);
    }

    @Override
    public List<SysAdminRoleRelation> selectByAdminIdsAndRoleIds(List<Long> adminIds,List<Long> roleIds){
        return mapper.selectByAdminIdsAndRoleIds(adminIds, roleIds);
    }

    @Override
    public int insert(List<SysAdminRoleRelation> record) {
        return mapper.insert(record);
    }


}
